package com.bytz.modules.cms.product.entity;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.bytz.common.aspect.annotation.Dict;
import com.bytz.modules.cms.user.model.IChangeEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * <p>
 * 莱宝CMS—产品管理—产品变动信息表
 * </p>
 *
 * @author KyleWang
 * @since 2022-10-10
 */
@Data
@ExcelIgnoreUnannotated
@EqualsAndHashCode(callSuper = false)
@TableName("cms_product_change")
@ApiModel(value = "ProductChange对象", description = "莱宝CMS—产品管理—产品变动信息表")
public class ProductChange implements Serializable, IChangeEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    private String id;

    @ApiModelProperty(value = "状态（1：调价，2：其他，3：修改产品其他信息）")
    private String type;

    @ApiModelProperty(value = "商品优惠分类id")
    private String productId;

    @ApiModelProperty(value = "产品线ID")
    private String productLineId;

    @ApiModelProperty(value = "产品线编码：SV/IV")
    private String productLineCode;

    @ApiModelProperty(value = "产品线名称")
    private String productLineName;

    @ApiModelProperty(value = "商品编号")
    @ExcelProperty("商品编号")
    private String productNumber;

    @ApiModelProperty(value = "商品描述")
    private String productDesc;

    @ApiModelProperty(value = "现优惠分类id")
    private String discountCategoryId;

    @ApiModelProperty(value = "现优惠分类名字")
    private String discountCategoryName;

    @ApiModelProperty(value = "现基准价")
    @ExcelProperty("基准价")
    private BigDecimal basePrice;

    @ApiModelProperty(value = "替换商品编号")
    private String replaceProductNumber;

    @ApiModelProperty(value = "是否属于EC产品")
    private String isEc;

    @ApiModelProperty(value = "状态（0：未上架，1：上架）")
    @Dict(dicCode = "product_status")
    private String status;

    @ApiModelProperty(value = "状态（0：未同步，1：已同步）")
    @Dict(dicCode = "batch_sync_status")
    private String syncStatus;

    @ApiModelProperty(value = "生效时间")
    private LocalDateTime effectTime;

    @ApiModelProperty(value = "失效时间")
    private LocalDateTime expiredTime;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "审批批次ID")
    private String auditBatchId;

    @ApiModelProperty(value = "删除状态")
    @TableLogic
    private Integer delFlag;

    @ApiModelProperty(value = "创建人")
    private String createBy;

    @ApiModelProperty(value = "创建人姓名")
    private String createByName;

    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新人")
    private String updateBy;

    @ApiModelProperty(value = "更新人姓名")
    private String updateByName;

    @ApiModelProperty(value = "更新时间")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "预计交期时间")
    private Integer deliveryDate;

    @ApiModelProperty(value = "最大订货数量")
    private Integer maxOrderQuantity;

    @ApiModelProperty(value = "成本价")
    private BigDecimal costPrice;


}